package com.example.p51;

import java.io.File;

/**
 * @author Lenovo
 */
public class Main {
    public static void main(String[] args) {
        File file = new File("./testdir");
        if (file.isDirectory()) {
            if (file.list().length > 0) {
                System.out.println("目录不为空");
            } else {
                System.out.println("目录为空");
            }
        }else {
                System.out.println("不是目录");
            }
        }
    }

